<?php
/**
 * Set methods for use operation in dbtable.
 * 
 * This is a class generated with Zend_CodeGenerator.
 * 
 * @category ###CATEGORY###
 * @package ###PACKAGE###
 * @subpackage ###SUBPACKAGE###
 * @version $Id$
 * @license New BSD
 */


class User_Model_ResourcesMapper extends Core_Model_Mapper_Abstract
{

    protected $_dbName = 'User_Model_DbTable_Resources';

    /**
     * Create new resource
     *
     * @param User_Model_Resources $resource
     * @return bool
     */
    public function addResource(User_Model_Resources $resource)
    {
        $newRow = $this->getDbTable()->createRow();

        $newRow->resource = $resource->getResource();
        $newRow->parent_id = $resource->getParent_id();

        return $newRow->save();
    }

}

